162de509b25083dc02520c73bcaa084f41ded77d,src/main/java/com/continuuity/passport/dal/db/AccountDBAccess.java,AccountDBAccess,getAccount,#number#,180

Before Change


      throw new ConfigurationException("DBConnection pool is null. DAO is not configured");
    }
    try {
      Connection connection = this.poolManager.getConnection();

      String SQL = String.format( "SELECT %s,%s,%s,%s,%s, %s FROM %s WHERE %s = ?",
                                  DBUtils.AccountTable.FIRST_NAME_COLUMN,DBUtils.AccountTable.LAST_NAME_COLUMN,
                                  DBUtils.AccountTable.COMPANY_COLUMN, DBUtils.AccountTable.EMAIL_COLUMN,
                                  DBUtils.AccountTable.ID_COLUMN, DBUtils.AccountTable.API_KEY_COLUMN,
                                  DBUtils.AccountTable.TABLE_NAME,
                                  DBUtils.AccountTable.ID_COLUMN);

      PreparedStatement ps = connection.prepareStatement(SQL);
      ps.setInt(1,accountId);
      ResultSet rs = ps.executeQuery();

      int count  = 0;
      while(rs.next()) {

After Change


      throw new ConfigurationException("DBConnection pool is null. DAO is not configured");
    }
    try {
      connection = this.poolManager.getConnection();

      String SQL = String.format("SELECT %s,%s,%s,%s,%s,%s,%s FROM %s WHERE %s = ?",
        DBUtils.AccountTable.FIRST_NAME_COLUMN, DBUtils.AccountTable.LAST_NAME_COLUMN,
        DBUtils.AccountTable.COMPANY_COLUMN, DBUtils.AccountTable.EMAIL_COLUMN,
        DBUtils.AccountTable.ID_COLUMN, DBUtils.AccountTable.API_KEY_COLUMN,
        DBUtils.AccountTable.CONFIRMED_COLUMN,
        DBUtils.AccountTable.TABLE_NAME,
        DBUtils.AccountTable.ID_COLUMN);

      ps = connection.prepareStatement(SQL);
      ps.setInt(1, accountId);
      rs = ps.executeQuery();


      int count = 0;